package com.myiam.idm.core.model;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;


public class Identity implements Serializable{
	
	/**
	 * 
	 */
	private static final long serialVersionUID = -5312365892319972913L;
	
	private long id;
	private String firstName;
	private String lastName;
	private List<PhoneNumber> phonenumbers;
	private List<Email> emails;
	private String employeeId;
	
	public long getId() {
		return id;
	}
	public void setId(long id) {
		this.id = id;
	}
	public String getFirstName() {
		return firstName;
	}
	public void setFirstName(String firstName) {
		this.firstName = firstName;
	}
	public String getLastName() {
		return lastName;
	}
	public void setLastName(String lastName) {
		this.lastName = lastName;
	}
	public List<PhoneNumber> getPhonenumbers() {
		if (phonenumbers == null) {
			phonenumbers= new ArrayList<PhoneNumber>();
		}		return phonenumbers;
	}
	public void setPhonenumbers(List<PhoneNumber> phonenumbers) {
		this.phonenumbers = phonenumbers;
	}
	public List<Email> getEmails() {
		if (emails == null) {
			emails= new ArrayList<Email>();
		}
		return emails;
	}
	public void setEmails(List<Email> emails) {
		this.emails = emails;
	}
	
	public void addEmail (Email email) {
		if (emails == null) {
			emails= new ArrayList<Email>();
		}
		
		emails.add(email);
	}
	
	public void addPhoneNumber(PhoneNumber phone) {
		if (phonenumbers == null) {
			phonenumbers = new ArrayList<PhoneNumber>();
		}
		
		
		phonenumbers.add(phone);
		
	}
	public String getEmployeeId() {
		return employeeId;
	}
	public void setEmployeeId(String employeeId) {
		this.employeeId = employeeId;
	}
	
	
}
